{"ast":null,"code":"import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport shallowEqual from 'shallowequal';\nimport useMergedState from \"rc-util/es/hooks/useMergedState\";\nimport Handles from './Handles';\nimport useDrag from './hooks/useDrag';\nimport SliderContext from './context';\nimport Tracks from './Tracks';\nimport Marks from './Marks';\nimport Steps from './Steps';\nimport useOffset from './hooks/useOffset';\nimport warning from \"rc-util/es/warning\";\nvar Slider = /*#__PURE__*/React.forwardRef(function (props, ref) {\n  var _classNames;\n  var _props$prefixCls = props.prefixCls,\n    prefixCls = _props$prefixCls === void 0 ? 'rc-slider' : _props$prefixCls,\n    className = props.className,\n    style = props.style,\n    _props$disabled = props.disabled,\n    disabled = _props$disabled === void 0 ? false : _props$disabled,\n    autoFocus = props.autoFocus,\n    onFocus = props.onFocus,\n    onBlur = props.onBlur,\n    _props$min = props.min,\n    min = _props$min === void 0 ? 0 : _props$min,\n    _props$max = props.max,\n    max = _props$max === void 0 ? 100 : _props$max,\n    _props$step = props.step,\n    step = _props$step === void 0 ? 1 : _props$step,\n    value = props.value,\n    defaultValue = props.defaultValue,\n    range = props.range,\n    count = props.count,\n    onChange = props.onChange,\n    onBeforeChange = props.onBeforeChange,\n    onAfterChange = props.onAfterChange,\n    _props$allowCross = props.allowCross,\n    allowCross = _props$allowCross === void 0 ? true : _props$allowCross,\n    _props$pushable = props.pushable,\n    pushable = _props$pushable === void 0 ? false : _props$pushable,\n    draggableTrack = props.draggableTrack,\n    reverse = props.reverse,\n    vertical = props.vertical,\n    _props$included = props.included,\n    included = _props$included === void 0 ? true : _props$included,\n    startPoint = props.startPoint,\n    trackStyle = props.trackStyle,\n    handleStyle = props.handleStyle,\n    railStyle = props.railStyle,\n    dotStyle = props.dotStyle,\n    activeDotStyle = props.activeDotStyle,\n    marks = props.marks,\n    dots = props.dots,\n    handleRender = props.handleRender,\n    _props$tabIndex = props.tabIndex,\n    tabIndex = _props$tabIndex === void 0 ? 0 : _props$tabIndex,\n    ariaLabelForHandle = props.ariaLabelForHandle,\n    ariaLabelledByForHandle = props.ariaLabelledByForHandle,\n    ariaValueTextFormatterForHandle = props.ariaValueTextFormatterForHandle;\n  var handlesRef = React.useRef();\n  var containerRef = React.useRef();\n  var direction = React.useMemo(function () {\n    if (vertical) {\n      return reverse ? 'ttb' : 'btt';\n    }\n    return reverse ? 'rtl' : 'ltr';\n  }, [reverse, vertical]); // ============================ Range =============================\n\n  var mergedMin = React.useMemo(function () {\n    return isFinite(min) ? min : 0;\n  }, [min]);\n  var mergedMax = React.useMemo(function () {\n    return isFinite(max) ? max : 100;\n  }, [max]); // ============================= Step =============================\n\n  var mergedStep = React.useMemo(function () {\n    return step !== null && step <= 0 ? 1 : step;\n  }, [step]); // ============================= Push =============================\n\n  var mergedPush = React.useMemo(function () {\n    if (pushable === true) {\n      return mergedStep;\n    }\n    return pushable >= 0 ? pushable : false;\n  }, [pushable, mergedStep]); // ============================ Marks =============================\n\n  var markList = React.useMemo(function () {\n    var keys = Object.keys(marks || {});\n    return keys.map(function (key) {\n      var mark = marks[key];\n      var markObj = {\n        value: Number(key)\n      };\n      if (mark && _typeof(mark) === 'object' && ! /*#__PURE__*/React.isValidElement(mark) && ('label' in mark || 'style' in mark)) {\n        markObj.style = mark.style;\n        markObj.label = mark.label;\n      } else {\n        markObj.label = mark;\n      }\n      return markObj;\n    }).filter(function (_ref) {\n      var label = _ref.label;\n      return label || typeof label === 'number';\n    }).sort(function (a, b) {\n      return a.value - b.value;\n    });\n  }, [marks]); // ============================ Format ============================\n\n  var _useOffset = useOffset(mergedMin, mergedMax, mergedStep, markList, allowCross, mergedPush),\n    _useOffset2 = _slicedToArray(_useOffset, 2),\n    formatValue = _useOffset2[0],\n    offsetValues = _useOffset2[1]; // ============================ Values ============================\n\n  var _useMergedState = useMergedState(defaultValue, {\n      value: value\n    }),\n    _useMergedState2 = _slicedToArray(_useMergedState, 2),\n    mergedValue = _useMergedState2[0],\n    setValue = _useMergedState2[1];\n  var rawValues = React.useMemo(function () {\n    var valueList = mergedValue === null || mergedValue === undefined ? [] : Array.isArray(mergedValue) ? mergedValue : [mergedValue];\n    var _valueList = _slicedToArray(valueList, 1),\n      _valueList$ = _valueList[0],\n      val0 = _valueList$ === void 0 ? mergedMin : _valueList$;\n    var returnValues = mergedValue === null ? [] : [val0]; // Format as range\n\n    if (range) {\n      returnValues = _toConsumableArray(valueList); // When count provided or value is `undefined`, we fill values\n\n      if (count || mergedValue === undefined) {\n        var pointCount = count >= 0 ? count + 1 : 2;\n        returnValues = returnValues.slice(0, pointCount); // Fill with count\n\n        while (returnValues.length < pointCount) {\n          var _returnValues;\n          returnValues.push((_returnValues = returnValues[returnValues.length - 1]) !== null && _returnValues !== void 0 ? _returnValues : mergedMin);\n        }\n      }\n      returnValues.sort(function (a, b) {\n        return a - b;\n      });\n    } // Align in range\n\n    returnValues.forEach(function (val, index) {\n      returnValues[index] = formatValue(val);\n    });\n    return returnValues;\n  }, [mergedValue, range, mergedMin, count, formatValue]); // =========================== onChange ===========================\n\n  var rawValuesRef = React.useRef(rawValues);\n  rawValuesRef.current = rawValues;\n  var getTriggerValue = function getTriggerValue(triggerValues) {\n    return range ? triggerValues : triggerValues[0];\n  };\n  var triggerChange = function triggerChange(nextValues) {\n    // Order first\n    var cloneNextValues = _toConsumableArray(nextValues).sort(function (a, b) {\n      return a - b;\n    }); // Trigger event if needed\n\n    if (onChange && !shallowEqual(cloneNextValues, rawValuesRef.current)) {\n      onChange(getTriggerValue(cloneNextValues));\n    } // We set this later since it will re-render component immediately\n\n    setValue(cloneNextValues);\n  };\n  var changeToCloseValue = function changeToCloseValue(newValue) {\n    if (!disabled) {\n      var valueIndex = 0;\n      var valueDist = mergedMax - mergedMin;\n      rawValues.forEach(function (val, index) {\n        var dist = Math.abs(newValue - val);\n        if (dist <= valueDist) {\n          valueDist = dist;\n          valueIndex = index;\n        }\n      }); // Create new values\n\n      var cloneNextValues = _toConsumableArray(rawValues);\n      cloneNextValues[valueIndex] = newValue; // Fill value to match default 2\n\n      if (range && !rawValues.length && count === undefined) {\n        cloneNextValues.push(newValue);\n      }\n      onBeforeChange === null || onBeforeChange === void 0 ? void 0 : onBeforeChange(getTriggerValue(cloneNextValues));\n      triggerChange(cloneNextValues);\n      onAfterChange === null || onAfterChange === void 0 ? void 0 : onAfterChange(getTriggerValue(cloneNextValues));\n    }\n  }; // ============================ Click =============================\n\n  var onSliderMouseDown = function onSliderMouseDown(e) {\n    e.preventDefault();\n    var _containerRef$current = containerRef.current.getBoundingClientRect(),\n      width = _containerRef$current.width,\n      height = _containerRef$current.height,\n      left = _containerRef$current.left,\n      top = _containerRef$current.top,\n      bottom = _containerRef$current.bottom,\n      right = _containerRef$current.right;\n    var clientX = e.clientX,\n      clientY = e.clientY;\n    var percent;\n    switch (direction) {\n      case 'btt':\n        percent = (bottom - clientY) / height;\n        break;\n      case 'ttb':\n        percent = (clientY - top) / height;\n        break;\n      case 'rtl':\n        percent = (right - clientX) / width;\n        break;\n      default:\n        percent = (clientX - left) / width;\n    }\n    var nextValue = mergedMin + percent * (mergedMax - mergedMin);\n    changeToCloseValue(formatValue(nextValue));\n  }; // =========================== Keyboard ===========================\n\n  var _React$useState = React.useState(null),\n    _React$useState2 = _slicedToArray(_React$useState, 2),\n    keyboardValue = _React$useState2[0],\n    setKeyboardValue = _React$useState2[1];\n  var onHandleOffsetChange = function onHandleOffsetChange(offset, valueIndex) {\n    if (!disabled) {\n      var next = offsetValues(rawValues, offset, valueIndex);\n      onBeforeChange === null || onBeforeChange === void 0 ? void 0 : onBeforeChange(getTriggerValue(rawValues));\n      triggerChange(next.values);\n      onAfterChange === null || onAfterChange === void 0 ? void 0 : onAfterChange(getTriggerValue(next.values));\n      setKeyboardValue(next.value);\n    }\n  };\n  React.useEffect(function () {\n    if (keyboardValue !== null) {\n      var valueIndex = rawValues.indexOf(keyboardValue);\n      if (valueIndex >= 0) {\n        handlesRef.current.focus(valueIndex);\n      }\n    }\n    setKeyboardValue(null);\n  }, [keyboardValue]); // ============================= Drag =============================\n\n  var mergedDraggableTrack = React.useMemo(function () {\n    if (draggableTrack && mergedStep === null) {\n      if (process.env.NODE_ENV !== 'production') {\n        warning(false, '`draggableTrack` is not supported when `step` is `null`.');\n      }\n      return false;\n    }\n    return draggableTrack;\n  }, [draggableTrack, mergedStep]);\n  var finishChange = function finishChange() {\n    onAfterChange === null || onAfterChange === void 0 ? void 0 : onAfterChange(getTriggerValue(rawValuesRef.current));\n  };\n  var _useDrag = useDrag(containerRef, direction, rawValues, mergedMin, mergedMax, formatValue, triggerChange, finishChange, offsetValues),\n    _useDrag2 = _slicedToArray(_useDrag, 4),\n    draggingIndex = _useDrag2[0],\n    draggingValue = _useDrag2[1],\n    cacheValues = _useDrag2[2],\n    onStartDrag = _useDrag2[3];\n  var onStartMove = function onStartMove(e, valueIndex) {\n    onStartDrag(e, valueIndex);\n    onBeforeChange === null || onBeforeChange === void 0 ? void 0 : onBeforeChange(getTriggerValue(rawValuesRef.current));\n  }; // Auto focus for updated handle\n\n  var dragging = draggingIndex !== -1;\n  React.useEffect(function () {\n    if (!dragging) {\n      var valueIndex = rawValues.lastIndexOf(draggingValue);\n      handlesRef.current.focus(valueIndex);\n    }\n  }, [dragging]); // =========================== Included ===========================\n\n  var sortedCacheValues = React.useMemo(function () {\n    return _toConsumableArray(cacheValues).sort(function (a, b) {\n      return a - b;\n    });\n  }, [cacheValues]); // Provide a range values with included [min, max]\n  // Used for Track, Mark & Dot\n\n  var _React$useMemo = React.useMemo(function () {\n      if (!range) {\n        return [mergedMin, sortedCacheValues[0]];\n      }\n      return [sortedCacheValues[0], sortedCacheValues[sortedCacheValues.length - 1]];\n    }, [sortedCacheValues, range, mergedMin]),\n    _React$useMemo2 = _slicedToArray(_React$useMemo, 2),\n    includedStart = _React$useMemo2[0],\n    includedEnd = _React$useMemo2[1]; // ============================= Refs =============================\n\n  React.useImperativeHandle(ref, function () {\n    return {\n      focus: function focus() {\n        handlesRef.current.focus(0);\n      },\n      blur: function blur() {\n        var _document = document,\n          activeElement = _document.activeElement;\n        if (containerRef.current.contains(activeElement)) {\n          activeElement === null || activeElement === void 0 ? void 0 : activeElement.blur();\n        }\n      }\n    };\n  }); // ========================== Auto Focus ==========================\n\n  React.useEffect(function () {\n    if (autoFocus) {\n      handlesRef.current.focus(0);\n    }\n  }, []); // =========================== Context ============================\n\n  var context = React.useMemo(function () {\n    return {\n      min: mergedMin,\n      max: mergedMax,\n      direction: direction,\n      disabled: disabled,\n      step: mergedStep,\n      included: included,\n      includedStart: includedStart,\n      includedEnd: includedEnd,\n      range: range,\n      tabIndex: tabIndex,\n      ariaLabelForHandle: ariaLabelForHandle,\n      ariaLabelledByForHandle: ariaLabelledByForHandle,\n      ariaValueTextFormatterForHandle: ariaValueTextFormatterForHandle\n    };\n  }, [mergedMin, mergedMax, direction, disabled, mergedStep, included, includedStart, includedEnd, range, tabIndex, ariaLabelForHandle, ariaLabelledByForHandle, ariaValueTextFormatterForHandle]); // ============================ Render ============================\n\n  return /*#__PURE__*/React.createElement(SliderContext.Provider, {\n    value: context\n  }, /*#__PURE__*/React.createElement(\"div\", {\n    ref: containerRef,\n    className: classNames(prefixCls, className, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-disabled\"), disabled), _defineProperty(_classNames, \"\".concat(prefixCls, \"-vertical\"), vertical), _defineProperty(_classNames, \"\".concat(prefixCls, \"-horizontal\"), !vertical), _defineProperty(_classNames, \"\".concat(prefixCls, \"-with-marks\"), markList.length), _classNames)),\n    style: style,\n    onMouseDown: onSliderMouseDown\n  }, /*#__PURE__*/React.createElement(\"div\", {\n    className: \"\".concat(prefixCls, \"-rail\"),\n    style: railStyle\n  }), /*#__PURE__*/React.createElement(Tracks, {\n    prefixCls: prefixCls,\n    style: trackStyle,\n    values: sortedCacheValues,\n    startPoint: startPoint,\n    onStartMove: mergedDraggableTrack ? onStartMove : null\n  }), /*#__PURE__*/React.createElement(Steps, {\n    prefixCls: prefixCls,\n    marks: markList,\n    dots: dots,\n    style: dotStyle,\n    activeStyle: activeDotStyle\n  }), /*#__PURE__*/React.createElement(Handles, {\n    ref: handlesRef,\n    prefixCls: prefixCls,\n    style: handleStyle,\n    values: cacheValues,\n    draggingIndex: draggingIndex,\n    onStartMove: onStartMove,\n    onOffsetChange: onHandleOffsetChange,\n    onFocus: onFocus,\n    onBlur: onBlur,\n    handleRender: handleRender\n  }), /*#__PURE__*/React.createElement(Marks, {\n    prefixCls: prefixCls,\n    marks: markList,\n    onClick: changeToCloseValue\n  })));\n});\nif (process.env.NODE_ENV !== 'production') {\n  Slider.displayName = 'Slider';\n}\nexport default Slider;","map":{"version":3,"names":["_defineProperty","_toConsumableArray","_slicedToArray","_typeof","React","classNames","shallowEqual","useMergedState","Handles","useDrag","SliderContext","Tracks","Marks","Steps","useOffset","warning","Slider","forwardRef","props","ref","_classNames","_props$prefixCls","prefixCls","className","style","_props$disabled","disabled","autoFocus","onFocus","onBlur","_props$min","min","_props$max","max","_props$step","step","value","defaultValue","range","count","onChange","onBeforeChange","onAfterChange","_props$allowCross","allowCross","_props$pushable","pushable","draggableTrack","reverse","vertical","_props$included","included","startPoint","trackStyle","handleStyle","railStyle","dotStyle","activeDotStyle","marks","dots","handleRender","_props$tabIndex","tabIndex","ariaLabelForHandle","ariaLabelledByForHandle","ariaValueTextFormatterForHandle","handlesRef","useRef","containerRef","direction","useMemo","mergedMin","isFinite","mergedMax","mergedStep","mergedPush","markList","keys","Object","map","key","mark","markObj","Number","isValidElement","label","filter","_ref","sort","a","b","_useOffset","_useOffset2","formatValue","offsetValues","_useMergedState","_useMergedState2","mergedValue","setValue","rawValues","valueList","undefined","Array","isArray","_valueList","_valueList$","val0","returnValues","pointCount","slice","length","_returnValues","push","forEach","val","index","rawValuesRef","current","getTriggerValue","triggerValues","triggerChange","nextValues","cloneNextValues","changeToCloseValue","newValue","valueIndex","valueDist","dist","Math","abs","onSliderMouseDown","e","preventDefault","_containerRef$current","getBoundingClientRect","width","height","left","top","bottom","right","clientX","clientY","percent","nextValue","_React$useState","useState","_React$useState2","keyboardValue","setKeyboardValue","onHandleOffsetChange","offset","next","values","useEffect","indexOf","focus","mergedDraggableTrack","process","env","NODE_ENV","finishChange","_useDrag","_useDrag2","draggingIndex","draggingValue","cacheValues","onStartDrag","onStartMove","dragging","lastIndexOf","sortedCacheValues","_React$useMemo","_React$useMemo2","includedStart","includedEnd","useImperativeHandle","blur","_document","document","activeElement","contains","context","createElement","Provider","concat","onMouseDown","activeStyle","onOffsetChange","onClick","displayName"],"sources":["/Users/poppie/Desktop/development/messenger/app/frontend/node_modules/rc-slider/es/Slider.js"],"sourcesContent":["import _defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\nimport _toConsumableArray from \"@babel/runtime/helpers/esm/toConsumableArray\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport * as React from 'react';\nimport classNames from 'classnames';\nimport shallowEqual from 'shallowequal';\nimport useMergedState from \"rc-util/es/hooks/useMergedState\";\nimport Handles from './Handles';\nimport useDrag from './hooks/useDrag';\nimport SliderContext from './context';\nimport Tracks from './Tracks';\nimport Marks from './Marks';\nimport Steps from './Steps';\nimport useOffset from './hooks/useOffset';\nimport warning from \"rc-util/es/warning\";\nvar Slider = /*#__PURE__*/React.forwardRef(function (props, ref) {\n  var _classNames;\n\n  var _props$prefixCls = props.prefixCls,\n      prefixCls = _props$prefixCls === void 0 ? 'rc-slider' : _props$prefixCls,\n      className = props.className,\n      style = props.style,\n      _props$disabled = props.disabled,\n      disabled = _props$disabled === void 0 ? false : _props$disabled,\n      autoFocus = props.autoFocus,\n      onFocus = props.onFocus,\n      onBlur = props.onBlur,\n      _props$min = props.min,\n      min = _props$min === void 0 ? 0 : _props$min,\n      _props$max = props.max,\n      max = _props$max === void 0 ? 100 : _props$max,\n      _props$step = props.step,\n      step = _props$step === void 0 ? 1 : _props$step,\n      value = props.value,\n      defaultValue = props.defaultValue,\n      range = props.range,\n      count = props.count,\n      onChange = props.onChange,\n      onBeforeChange = props.onBeforeChange,\n      onAfterChange = props.onAfterChange,\n      _props$allowCross = props.allowCross,\n      allowCross = _props$allowCross === void 0 ? true : _props$allowCross,\n      _props$pushable = props.pushable,\n      pushable = _props$pushable === void 0 ? false : _props$pushable,\n      draggableTrack = props.draggableTrack,\n      reverse = props.reverse,\n      vertical = props.vertical,\n      _props$included = props.included,\n      included = _props$included === void 0 ? true : _props$included,\n      startPoint = props.startPoint,\n      trackStyle = props.trackStyle,\n      handleStyle = props.handleStyle,\n      railStyle = props.railStyle,\n      dotStyle = props.dotStyle,\n      activeDotStyle = props.activeDotStyle,\n      marks = props.marks,\n      dots = props.dots,\n      handleRender = props.handleRender,\n      _props$tabIndex = props.tabIndex,\n      tabIndex = _props$tabIndex === void 0 ? 0 : _props$tabIndex,\n      ariaLabelForHandle = props.ariaLabelForHandle,\n      ariaLabelledByForHandle = props.ariaLabelledByForHandle,\n      ariaValueTextFormatterForHandle = props.ariaValueTextFormatterForHandle;\n  var handlesRef = React.useRef();\n  var containerRef = React.useRef();\n  var direction = React.useMemo(function () {\n    if (vertical) {\n      return reverse ? 'ttb' : 'btt';\n    }\n\n    return reverse ? 'rtl' : 'ltr';\n  }, [reverse, vertical]); // ============================ Range =============================\n\n  var mergedMin = React.useMemo(function () {\n    return isFinite(min) ? min : 0;\n  }, [min]);\n  var mergedMax = React.useMemo(function () {\n    return isFinite(max) ? max : 100;\n  }, [max]); // ============================= Step =============================\n\n  var mergedStep = React.useMemo(function () {\n    return step !== null && step <= 0 ? 1 : step;\n  }, [step]); // ============================= Push =============================\n\n  var mergedPush = React.useMemo(function () {\n    if (pushable === true) {\n      return mergedStep;\n    }\n\n    return pushable >= 0 ? pushable : false;\n  }, [pushable, mergedStep]); // ============================ Marks =============================\n\n  var markList = React.useMemo(function () {\n    var keys = Object.keys(marks || {});\n    return keys.map(function (key) {\n      var mark = marks[key];\n      var markObj = {\n        value: Number(key)\n      };\n\n      if (mark && _typeof(mark) === 'object' && ! /*#__PURE__*/React.isValidElement(mark) && ('label' in mark || 'style' in mark)) {\n        markObj.style = mark.style;\n        markObj.label = mark.label;\n      } else {\n        markObj.label = mark;\n      }\n\n      return markObj;\n    }).filter(function (_ref) {\n      var label = _ref.label;\n      return label || typeof label === 'number';\n    }).sort(function (a, b) {\n      return a.value - b.value;\n    });\n  }, [marks]); // ============================ Format ============================\n\n  var _useOffset = useOffset(mergedMin, mergedMax, mergedStep, markList, allowCross, mergedPush),\n      _useOffset2 = _slicedToArray(_useOffset, 2),\n      formatValue = _useOffset2[0],\n      offsetValues = _useOffset2[1]; // ============================ Values ============================\n\n\n  var _useMergedState = useMergedState(defaultValue, {\n    value: value\n  }),\n      _useMergedState2 = _slicedToArray(_useMergedState, 2),\n      mergedValue = _useMergedState2[0],\n      setValue = _useMergedState2[1];\n\n  var rawValues = React.useMemo(function () {\n    var valueList = mergedValue === null || mergedValue === undefined ? [] : Array.isArray(mergedValue) ? mergedValue : [mergedValue];\n\n    var _valueList = _slicedToArray(valueList, 1),\n        _valueList$ = _valueList[0],\n        val0 = _valueList$ === void 0 ? mergedMin : _valueList$;\n\n    var returnValues = mergedValue === null ? [] : [val0]; // Format as range\n\n    if (range) {\n      returnValues = _toConsumableArray(valueList); // When count provided or value is `undefined`, we fill values\n\n      if (count || mergedValue === undefined) {\n        var pointCount = count >= 0 ? count + 1 : 2;\n        returnValues = returnValues.slice(0, pointCount); // Fill with count\n\n        while (returnValues.length < pointCount) {\n          var _returnValues;\n\n          returnValues.push((_returnValues = returnValues[returnValues.length - 1]) !== null && _returnValues !== void 0 ? _returnValues : mergedMin);\n        }\n      }\n\n      returnValues.sort(function (a, b) {\n        return a - b;\n      });\n    } // Align in range\n\n\n    returnValues.forEach(function (val, index) {\n      returnValues[index] = formatValue(val);\n    });\n    return returnValues;\n  }, [mergedValue, range, mergedMin, count, formatValue]); // =========================== onChange ===========================\n\n  var rawValuesRef = React.useRef(rawValues);\n  rawValuesRef.current = rawValues;\n\n  var getTriggerValue = function getTriggerValue(triggerValues) {\n    return range ? triggerValues : triggerValues[0];\n  };\n\n  var triggerChange = function triggerChange(nextValues) {\n    // Order first\n    var cloneNextValues = _toConsumableArray(nextValues).sort(function (a, b) {\n      return a - b;\n    }); // Trigger event if needed\n\n\n    if (onChange && !shallowEqual(cloneNextValues, rawValuesRef.current)) {\n      onChange(getTriggerValue(cloneNextValues));\n    } // We set this later since it will re-render component immediately\n\n\n    setValue(cloneNextValues);\n  };\n\n  var changeToCloseValue = function changeToCloseValue(newValue) {\n    if (!disabled) {\n      var valueIndex = 0;\n      var valueDist = mergedMax - mergedMin;\n      rawValues.forEach(function (val, index) {\n        var dist = Math.abs(newValue - val);\n\n        if (dist <= valueDist) {\n          valueDist = dist;\n          valueIndex = index;\n        }\n      }); // Create new values\n\n      var cloneNextValues = _toConsumableArray(rawValues);\n\n      cloneNextValues[valueIndex] = newValue; // Fill value to match default 2\n\n      if (range && !rawValues.length && count === undefined) {\n        cloneNextValues.push(newValue);\n      }\n\n      onBeforeChange === null || onBeforeChange === void 0 ? void 0 : onBeforeChange(getTriggerValue(cloneNextValues));\n      triggerChange(cloneNextValues);\n      onAfterChange === null || onAfterChange === void 0 ? void 0 : onAfterChange(getTriggerValue(cloneNextValues));\n    }\n  }; // ============================ Click =============================\n\n\n  var onSliderMouseDown = function onSliderMouseDown(e) {\n    e.preventDefault();\n\n    var _containerRef$current = containerRef.current.getBoundingClientRect(),\n        width = _containerRef$current.width,\n        height = _containerRef$current.height,\n        left = _containerRef$current.left,\n        top = _containerRef$current.top,\n        bottom = _containerRef$current.bottom,\n        right = _containerRef$current.right;\n\n    var clientX = e.clientX,\n        clientY = e.clientY;\n    var percent;\n\n    switch (direction) {\n      case 'btt':\n        percent = (bottom - clientY) / height;\n        break;\n\n      case 'ttb':\n        percent = (clientY - top) / height;\n        break;\n\n      case 'rtl':\n        percent = (right - clientX) / width;\n        break;\n\n      default:\n        percent = (clientX - left) / width;\n    }\n\n    var nextValue = mergedMin + percent * (mergedMax - mergedMin);\n    changeToCloseValue(formatValue(nextValue));\n  }; // =========================== Keyboard ===========================\n\n\n  var _React$useState = React.useState(null),\n      _React$useState2 = _slicedToArray(_React$useState, 2),\n      keyboardValue = _React$useState2[0],\n      setKeyboardValue = _React$useState2[1];\n\n  var onHandleOffsetChange = function onHandleOffsetChange(offset, valueIndex) {\n    if (!disabled) {\n      var next = offsetValues(rawValues, offset, valueIndex);\n      onBeforeChange === null || onBeforeChange === void 0 ? void 0 : onBeforeChange(getTriggerValue(rawValues));\n      triggerChange(next.values);\n      onAfterChange === null || onAfterChange === void 0 ? void 0 : onAfterChange(getTriggerValue(next.values));\n      setKeyboardValue(next.value);\n    }\n  };\n\n  React.useEffect(function () {\n    if (keyboardValue !== null) {\n      var valueIndex = rawValues.indexOf(keyboardValue);\n\n      if (valueIndex >= 0) {\n        handlesRef.current.focus(valueIndex);\n      }\n    }\n\n    setKeyboardValue(null);\n  }, [keyboardValue]); // ============================= Drag =============================\n\n  var mergedDraggableTrack = React.useMemo(function () {\n    if (draggableTrack && mergedStep === null) {\n      if (process.env.NODE_ENV !== 'production') {\n        warning(false, '`draggableTrack` is not supported when `step` is `null`.');\n      }\n\n      return false;\n    }\n\n    return draggableTrack;\n  }, [draggableTrack, mergedStep]);\n\n  var finishChange = function finishChange() {\n    onAfterChange === null || onAfterChange === void 0 ? void 0 : onAfterChange(getTriggerValue(rawValuesRef.current));\n  };\n\n  var _useDrag = useDrag(containerRef, direction, rawValues, mergedMin, mergedMax, formatValue, triggerChange, finishChange, offsetValues),\n      _useDrag2 = _slicedToArray(_useDrag, 4),\n      draggingIndex = _useDrag2[0],\n      draggingValue = _useDrag2[1],\n      cacheValues = _useDrag2[2],\n      onStartDrag = _useDrag2[3];\n\n  var onStartMove = function onStartMove(e, valueIndex) {\n    onStartDrag(e, valueIndex);\n    onBeforeChange === null || onBeforeChange === void 0 ? void 0 : onBeforeChange(getTriggerValue(rawValuesRef.current));\n  }; // Auto focus for updated handle\n\n\n  var dragging = draggingIndex !== -1;\n  React.useEffect(function () {\n    if (!dragging) {\n      var valueIndex = rawValues.lastIndexOf(draggingValue);\n      handlesRef.current.focus(valueIndex);\n    }\n  }, [dragging]); // =========================== Included ===========================\n\n  var sortedCacheValues = React.useMemo(function () {\n    return _toConsumableArray(cacheValues).sort(function (a, b) {\n      return a - b;\n    });\n  }, [cacheValues]); // Provide a range values with included [min, max]\n  // Used for Track, Mark & Dot\n\n  var _React$useMemo = React.useMemo(function () {\n    if (!range) {\n      return [mergedMin, sortedCacheValues[0]];\n    }\n\n    return [sortedCacheValues[0], sortedCacheValues[sortedCacheValues.length - 1]];\n  }, [sortedCacheValues, range, mergedMin]),\n      _React$useMemo2 = _slicedToArray(_React$useMemo, 2),\n      includedStart = _React$useMemo2[0],\n      includedEnd = _React$useMemo2[1]; // ============================= Refs =============================\n\n\n  React.useImperativeHandle(ref, function () {\n    return {\n      focus: function focus() {\n        handlesRef.current.focus(0);\n      },\n      blur: function blur() {\n        var _document = document,\n            activeElement = _document.activeElement;\n\n        if (containerRef.current.contains(activeElement)) {\n          activeElement === null || activeElement === void 0 ? void 0 : activeElement.blur();\n        }\n      }\n    };\n  }); // ========================== Auto Focus ==========================\n\n  React.useEffect(function () {\n    if (autoFocus) {\n      handlesRef.current.focus(0);\n    }\n  }, []); // =========================== Context ============================\n\n  var context = React.useMemo(function () {\n    return {\n      min: mergedMin,\n      max: mergedMax,\n      direction: direction,\n      disabled: disabled,\n      step: mergedStep,\n      included: included,\n      includedStart: includedStart,\n      includedEnd: includedEnd,\n      range: range,\n      tabIndex: tabIndex,\n      ariaLabelForHandle: ariaLabelForHandle,\n      ariaLabelledByForHandle: ariaLabelledByForHandle,\n      ariaValueTextFormatterForHandle: ariaValueTextFormatterForHandle\n    };\n  }, [mergedMin, mergedMax, direction, disabled, mergedStep, included, includedStart, includedEnd, range, tabIndex, ariaLabelForHandle, ariaLabelledByForHandle, ariaValueTextFormatterForHandle]); // ============================ Render ============================\n\n  return /*#__PURE__*/React.createElement(SliderContext.Provider, {\n    value: context\n  }, /*#__PURE__*/React.createElement(\"div\", {\n    ref: containerRef,\n    className: classNames(prefixCls, className, (_classNames = {}, _defineProperty(_classNames, \"\".concat(prefixCls, \"-disabled\"), disabled), _defineProperty(_classNames, \"\".concat(prefixCls, \"-vertical\"), vertical), _defineProperty(_classNames, \"\".concat(prefixCls, \"-horizontal\"), !vertical), _defineProperty(_classNames, \"\".concat(prefixCls, \"-with-marks\"), markList.length), _classNames)),\n    style: style,\n    onMouseDown: onSliderMouseDown\n  }, /*#__PURE__*/React.createElement(\"div\", {\n    className: \"\".concat(prefixCls, \"-rail\"),\n    style: railStyle\n  }), /*#__PURE__*/React.createElement(Tracks, {\n    prefixCls: prefixCls,\n    style: trackStyle,\n    values: sortedCacheValues,\n    startPoint: startPoint,\n    onStartMove: mergedDraggableTrack ? onStartMove : null\n  }), /*#__PURE__*/React.createElement(Steps, {\n    prefixCls: prefixCls,\n    marks: markList,\n    dots: dots,\n    style: dotStyle,\n    activeStyle: activeDotStyle\n  }), /*#__PURE__*/React.createElement(Handles, {\n    ref: handlesRef,\n    prefixCls: prefixCls,\n    style: handleStyle,\n    values: cacheValues,\n    draggingIndex: draggingIndex,\n    onStartMove: onStartMove,\n    onOffsetChange: onHandleOffsetChange,\n    onFocus: onFocus,\n    onBlur: onBlur,\n    handleRender: handleRender\n  }), /*#__PURE__*/React.createElement(Marks, {\n    prefixCls: prefixCls,\n    marks: markList,\n    onClick: changeToCloseValue\n  })));\n});\n\nif (process.env.NODE_ENV !== 'production') {\n  Slider.displayName = 'Slider';\n}\n\nexport default Slider;"],"mappings":"AAAA,OAAOA,eAAe,MAAM,2CAA2C;AACvE,OAAOC,kBAAkB,M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